package eventStrategies.component;

import java.util.ArrayList;

import utilities.Key;

import eventManager.AppEvent;
import eventManager.EventPortal;
import modifiers.DataModifier;
import modifiers.IEventResponse;

public class ApplyDataModifierStrategy implements IEventResponse {

	private ArrayList<String> eventTypes = new ArrayList<String>();
	private Key target;
	private DataModifier dataMod;
	
	public ApplyDataModifierStrategy(Key target, DataModifier dataMod) {
		eventTypes.add("applyDataModifier");
		this.target = target;
		this.dataMod = dataMod;
	}
	
	public ArrayList<String> getEventTypes() {
		return eventTypes;
	}

	public void execute(AppEvent event) {
		Object[] objs = new Object[]{dataMod};
		EventPortal.queueEvent(new AppEvent("applyDataModifier", objs));		
	}

}
